package de.koller.million.card.engine.player;

import de.koller.million.card.engine.item.Item;

public class PlayerStats {

	private final Player player;
	private double damage = 0;
	
	public PlayerStats( Player player ) {
		this.player = player;
	}
	
	public void equiptChanged() {
		double lastDamage = damage;
		
		damage = 0;
		for( Item i : player.equipt.equipt.values() )
			damage += i.getDamage();
		
		if( damage > lastDamage )
			player.croot.engine.playerContainer.newDamageEquipt( player );
	}
	
	public double getDamage() {
		return damage;
	}
}
